package r21310.chap04.d1002;

import java.io.PrintStream;
import java.util.Scanner;

public class ruku {
    static phone[] phones = new phone[10];

    public ruku() {
    }

    public static void main(String[] args) {
        for(int i = 0; i < phones.length; ++i) {
            PrintStream var10000 = System.out;
            String var10001 = phones[i].getBrand();
            var10000.println("品牌：" + var10001 + "屏幕尺寸：" + phones[i].getSize() + "手机价格：" + phones[i].getPrice() + "手机配置：" + phones[i].getMemory());
            phone var2 = phones[i];
            System.out.println("库存数量" + var2.getQuantity());
            var10000 = System.out;
            double var3 = (double)phones[i].getQuantity();
            phone var10002 = phones[i];
            var10000.println("总价值" + var3 * var10002.getPrice());
        }

    }

    static {
        Scanner h = new Scanner(System.in);

        for(int i = 0; i < 10; ++i) {
            System.out.println("请输入商品数量输入0结束");
            int t = h.nextInt();
            if (t == 0) {
                System.exit(0);
            } else {
                System.out.println("输入商品信息");
                System.out.println("请输入手机品牌");
                String q = h.next();
                System.out.println("请输入手机尺寸");
                float w = h.nextFloat();
                System.out.println("请输入手机价格");
                double e = h.nextDouble();
                System.out.println("请输入手机配置");
                String r = h.next();
                phones[i] = new phone(t, q, w, e, r);
            }
        }

    }
}

